package com.ysd.lis.entity.lab;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ysd.lis.entity.BaseEntity;
import com.ysd.lis.entity.BaseEntityJpa;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.math.BigDecimal;

/**
 * <p>
 *
 * </p>
 *
 * @author yangjianguang
 * @since 2023-12-15
 */
@Entity
@Table(name = "LAB_ITEM_DICT")
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("LAB_ITEM_DICT")
public class LabItemDict extends BaseEntityJpa {

    private static final long serialVersionUID = 1L;

    @Column(name = "ITEM_NO")
    @TableField("ITEM_NO")
    private String itemNo;  //项目代码

    @Column(name = "BAS_ITEM_CODE")
    @TableField("BAS_ITEM_CODE")
    private String basItemCode;  //基础项目代码

    @TableField("ITEM_NA")
    @Column(name = "ITEM_NA")
    private String itemNa;  //项目名称

    @TableField("ITEM_EN_NAME")
    @Column(name = "ITEM_EN_NAME")
    private String itemEnName;  //项目英文名称

    @TableField("ITEM_EN_CODE")
    @Column(name = "ITEM_EN_CODE")
    private String itemEnCode;  //项目英文缩写

    @TableField("INPUT_CODE")
    @Column(name = "INPUT_CODE")
    private String inputCode;  //助记码/输入码

    @TableField("REMARK")
    @Column(name = "REMARK")
    private String remark;  //备注

    @TableField("ENABLE")
    @Column(name = "ENABLE")
    private Integer enable;  //是否启用

    @TableField("SEQ")
    @Column(name = "SEQ")
    private Integer seq;  //排序码

    @TableField("ITEM_CLASS")
    @Column(name = "ITEM_CLASS")
    private String itemClass;  //项目归类

    @TableField("INSTR_CLASS")
    @Column(name = "INSTR_CLASS")
    private String instrClass;  //仪器大类

    @TableField("RPT_GROUP")
    @Column(name = "RPT_GROUP")
    private String rptGroup;  //报告单元

    @TableField("ITEM_KIND")
    @Column(name = "ITEM_KIND")
    private String itemKind;  //项目结果类别（分为：1数值型、2文字型、3阴阳性、4数值文字混合型）

    @TableField("DEC_POS")
    @Column(name = "DEC_POS")
    private String decPos;  //小数保留位数

    @TableField("UNIT")
    @Column(name = "UNIT")
    private String unit;  //单位

    @TableField("PRICE")
    @Column(name = "PRICE")
    private BigDecimal price;  //价格

    @TableField("REPORT_CODE")
    @Column(name = "REPORT_CODE")
    private String reportCode;  //报告代码

    @TableField("FEE_CODE")
    @Column(name = "FEE_CODE")
    private String feeCode;  //申请代码

    @TableField("COUNT_CODE")
    @Column(name = "COUNT_CODE")
    private String countCode;  //统计代码

    @TableField("BASE_CODE")
    @Column(name = "BASE_CODE")
    private String baseCode;  //标准项目代码

    @TableField("DEFAULT_VAL")
    @Column(name = "DEFAULT_VAL")
    private String defaultVal;  //默认值

    @TableField("TEST_METHOD")
    @Column(name = "TEST_METHOD")
    private String testMethod;  //测试方法

    @TableField("IS_TRAN")
    @Column(name = "IS_TRAN")
    private String isTran;  //是否通道号转译 1是 0非

    @TableField(exist = false)
    @Transient
    private String searchValue;
    @TableField(exist = false)
    @Transient
    private String rptGroupName;
    @TableField(exist = false)
    @Transient
    private Integer rptSeq;

    /**
     * 与报告项目对照id
     */
    @TableField(exist = false)
    @Transient
    private String isOptional;
    @TableField(exist = false)
    @Transient
    private String externalCodeOne;
    @TableField(exist = false)
    @Transient
    private String externalCodeTwo;
    @TableField(exist = false)
    @Transient
    private String externalCodeThree;
    @TableField(exist = false)
    @Transient
    private String feeVSItemDictId;
    @TableField(exist = false)
    @Transient
    private String rulesVSItemDictId;
    @TableField(exist = false)
    @Transient
    private String feeItemCode;
    @TableField(exist = false)
    @Transient
    private String feeItemName;


    /**
     * 急诊申请项目
     */
    @TableField("ER_FEEITEM_CODE")
    @Column(name = "ER_FEEITEM_CODE")
    private String erFeeitemCode;
    /**
     * 急诊申请项目名称
     */
    @TableField(exist = false)
    @Transient
    private String erFeeitemName;
    /**
     * 结果默认值1
     */
    @TableField("DEF_VALUE1")
    @Column(name = "DEF_VALUE1")
    private String defValue1;

    /**
     * 结果默认值2
     */
    @TableField("DEF_VALUE2")
    @Column(name = "DEF_VALUE2")
    private String defValue2;

    /**
     * 结果默认值3
     */
    @TableField("DEF_VALUE3")
    @Column(name = "DEF_VALUE3")
    private String defValue3;

    /**
     * Gram一级分类
     */
    @TableField("GRAM_TYPE")
    @Column(name = "GRAM_TYPE")
    private String gramType;

    /**
     * 菌科(二级分类)
     */
    @TableField("FUNGAL_FAMILY")
    @Column(name = "FUNGAL_FAMILY")
    private String fungalFamily;

    /**
     * 菌属(三级分类)
     */
    @TableField("FUNGAL_GENUS")
    @Column(name = "FUNGAL_GENUS")
    private String fungalGenus;

    /**
     * 默认药敏组合
     */
    @TableField("DEF_DRUG_COMB")
    @Column(name = "DEF_DRUG_COMB")
    private String defDrugComb;

    /**
     * 基因输入模板
     */
    @TableField("GENE_INPUT_TEMP")
    @Column(name = "GENE_INPUT_TEMP")
    private String geneInputTemp;

    /**
     * 计算用默认取值
     */
    @TableField("DEF_CALC_VALUE")
    @Column(name = "DEF_CALC_VALUE")
    private String defCalcValue;

    /**
     * WhoNet代码
     */
    @TableField("WHONET_CODE")
    @Column(name = "WHONET_CODE")
    private String whonetCode;

    /**
     * 默认文字结果标志
     */
    @TableField("DEF_TEXT_RESULT_FLAG")
    @Column(name = "DEF_TEXT_RESULT_FLAG")
    private String defTextResultFlag;

    /**
     * 样本质量
     */
    @TableField("SAMPLE_QUALITY")
    @Column(name = "SAMPLE_QUALITY")
    private String sampleQuality;

    /**
     * 对照项目
     */
    @TableField("MAPPER_ITEM_CODE")
    @Column(name = "MAPPER_ITEM_CODE")
    private String mapperItemCode;
    /**
     * 对照项目名称
     */
    @TableField(exist = false)
    @Transient
    private String mapperItemName;

    /**
     * 编号归类
     */
    @TableField("NUM_TYPE")
    @Column(name = "NUM_TYPE")
    private String numType;

    /**
     * 结果互认代码
     */
    @TableField("RESULT_MUTU_CODE")
    @Column(name = "RESULT_MUTU_CODE")
    private String resultMutuCode;

    /**
     * 结果互认代码
     */
    @TableField("RESULT_MUTU_NAME")
    @Column(name = "RESULT_MUTU_NAME")
    private String resultMutuName;

    /**
     * HIS对照代码
     */
    @TableField("HIS_ITEM_CODE")
    @Column(name = "HIS_ITEM_CODE")
    private String hisItemCode;

    /**
     * 体检对照代码
     */
    @TableField("PHYS_ITEM_CODE")
    @Column(name = "PHYS_ITEM_CODE")
    private String physItemCode;

    /**
     * 结果超出数
     */
    @TableField("OUT_RESULT_NUM")
    @Column(name = "OUT_RESULT_NUM")
    private BigDecimal outResultNum;

    /**
     * 结果超出稀释倍数
     */
    @TableField("OUT_RESULT_DILU_FACTOR")
    @Column(name = "OUT_RESULT_DILU_FACTOR")
    private BigDecimal outResultDiluFactor;

    /**
     * 允许CV(%)
     */
    @TableField("ALLOW_CV_PERCT")
    @Column(name = "ALLOW_CV_PERCT")
    private BigDecimal allowCvPerct;

    /**
     * 允许TEa(%)
     */
    @TableField("ALLOW_TEA_PERCT")
    @Column(name = "ALLOW_TEA_PERCT")
    private BigDecimal allowTeaPerct;

    /**
     * 工作量
     */
    @TableField("WORK_LOAD")
    @Column(name = "WORK_LOAD")
    private BigDecimal workLoad;

    /**
     * 是否参与统计  0 否 1 是
     */
    @TableField("IS_STATISTICS")
    @Column(name = "IS_STATISTICS")
    private Integer isStatistics;

    /**
     * 是否报告  0 否 1 是
     */
    @TableField("IS_REPORT")
    @Column(name = "IS_REPORT")
    private Integer isReport;

    /**
     * 是否质控  0 否 1 是
     */
    @TableField("IS_QC")
    @Column(name = "IS_QC")
    private Integer isQc;

    /**
     * 室间质控  0 否 1 是
     */
    @TableField("IS_EQC")
    @Column(name = "IS_EQC")
    private Integer isEqc;

    /**
     * 计算项目  0 否 1 是
     */
    @TableField("IS_CALC_ITEM")
    @Column(name = "IS_CALC_ITEM")
    private Integer isCalcItem;

    /**
     * 计算项目公式
     */
    @TableField("CALC_ITEM_FORMULA")
    @Column(name = "CALC_ITEM_FORMULA")
    private String calcItemFormula;

    /**
     * 计算公式说明
     */
    @TableField("CALC_ITEM_DESCRIPTION")
    @Column(name = "CALC_ITEM_DESCRIPTION")
    private String calcItemDescription;

    /**
     * 结果1计算公式
     */
    @TableField("RESULT1_FORMULA")
    @Column(name = "RESULT1_FORMULA")
    private String result1Formula;

    /**
     * 结果2计算公式
     */
    @TableField("RESULT2_FORMULA")
    @Column(name = "RESULT2_FORMULA")
    private String result2Formula;

    /**
     * 结果3计算公式
     */
    @TableField("RESULT3_FORMULA")
    @Column(name = "RESULT3_FORMULA")
    private String result3Formula;

    /**
     * 预留字段1
     */
    @TableField("RESE_ATTRI1")
    @Column(name = "RESE_ATTRI1")
    private String reseAttri1;

    /**
     * 预留字段2
     */
    @TableField("RESE_ATTRI2")
    @Column(name = "RESE_ATTRI2")
    private String reseAttri2;

    /**
     * 预留字段3
     */
    @TableField("RESE_ATTRI3")
    @Column(name = "RESE_ATTRI3")
    private String reseAttri3;

    /**
     * 预留字段4
     */
    @TableField("RESE_ATTRI4")
    @Column(name = "RESE_ATTRI4")
    private String reseAttri4;

    /**
     * 预留字段5
     */
    @TableField("RESE_ATTRI5")
    @Column(name = "RESE_ATTRI5")
    private String reseAttri5;

    /**
     * 下限
     */
    @TableField("LNUM")
    @Column(name = "LNUM")
    private String lnum;

    /**
     * 上限
     */
    @TableField("HNUM")
    @Column(name = "HNUM")
    private String hnum;

    /**
     * 参考值
     */
    @TableField("REF")
    @Column(name = "REF")
    private String ref;

    /**
     * 结果小于下限结果标志
     */
    @TableField("LFLAG")
    @Column(name = "LFLAG")
    private String lflag;

    /**
     * 结果大于上线结果标志
     */
    @TableField("HFLAG")
    @Column(name = "HFLAG")
    private String hflag;

    @TableField("POCT")
    @Column(name = "POCT")
    private Integer poct;


    /**
     * 项目名称（互认）
     */
    @TableField("HR_ITEM_NAME")
    @Column(name = "HR_ITEM_NAME")
    private String hrItemName;


    /**
     * 项目代码（互认）
     */
    @TableField("HR_ITEM_CODE")
    @Column(name = "HR_ITEM_CODE")
    private String hrItemCode;

}
